package vue;

import java.awt.Dimension;
import java.awt.Graphics;
import java.awt.image.BufferedImage;

import java.io.File;
import java.io.IOException;

import javax.imageio.ImageIO;
import javax.swing.JPanel;

import memory.Memory;

@SuppressWarnings("serial")
public class VSmiley extends JPanel {
	
	protected BufferedImage smile;
	
	public VSmiley() {
		try {
			smile = ImageIO.read(getClass().getResourceAsStream("success.png"));
		}
		catch (IOException e) {}
		setPreferredSize(new Dimension(smile.getWidth(), smile.getHeight()));
		setBackground(Memory.BG_COLOR.brighter());
	}
	
	@Override
	public void paintComponent(Graphics g) {
		g.drawImage(smile, 0, 0, null);
	}
}
